package com.rivulet.doj_backend.mapper;

import com.rivulet.doj_backend.pojo.User;
import com.rivulet.doj_backend.pojo.UserInformation;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Component;

@Component
public interface UserInformationMapper {
    @Update("update t_user_information set nickname = #{nickname},age=#{age},sex=#{sex},phone_number=#{phone_number} where id = #{id}")
    public void updateUserInformationById(@Param("nickname") String nickname, @Param("age") Integer age, @Param("sex") Integer sex, @Param("phone_number") String phone_number, @Param("id") Integer id);
    @Select("select * from t_user_information where id = #{id}")
    public UserInformation getUserInformationById(@Param("id") Integer id);

}
